//
//  NSString+String.m
//  THJXHW
//
//  Created by 河南德艺 on 17/4/12.
//  Copyright © 2017年 河南德艺. All rights reserved.
//

#import "NSString+String.h"

@implementation NSString (String)
+ (BOOL)isMobileNumber:(NSString *)mobileNum {

//    NSString *MOBILE = @"^1(3[0-9]|4[57]|5[0-35-9]|8[0-9]|7[0135678])\\d{8}$";
//    
//    NSPredicate *regextestmobile = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", MOBILE];
//    
//    return [regextestmobile evaluateWithObject:mobileNum];
    if(mobileNum.length == 11 && [mobileNum hasPrefix:@"1"]){
        return YES;
    }else{
        return NO;
    }
}
@end
